package com.jvm.shk;

import java.text.SimpleDateFormat;
import java.time.LocalDate;
import java.time.LocalDateTime;
import java.util.ArrayList;
import java.util.logging.SimpleFormatter;

/**
 * @author ：qs
 * @date ：Created in 2022/9/19
 * @description：
 * @modified By：
 * -Xms60m -Xmx60m -XX:SurvivorRatio=8
 */
public class GCTest {

    public static void main(String[] args) {
        ArrayList<byte[]> list = new ArrayList<>();
        for (int i = 0; i < 1000; i++) {
            byte[] arr = new byte[1024*100]; // 100KB
            list.add(arr);
            try {
                System.out.println("第" + i + "次, " + LocalDateTime.now());
                Thread.sleep(50000);
            } catch (InterruptedException e) {
                e.printStackTrace();
            }
        }
    }
}
